1. Technology Field
The present invention relates to a wear leveling method, and particularly relates to a wear leveling method for a non-volatile memory module, a memory storage device, and a memory control circuit unit.
2. Description of Related Art
The growth of digital cameras, mobile phones, and MP3 players has been rapid in recent years. Consequently, the consumers' demand for storage media has increased tremendously. Since the rewritable non-volatile memory has the characteristics of data non-volatility, low power consumption, compact size, non-mechanical structure, and fast reading/writing speed, the rewritable non-volatile memory has gained its popularity in electronic industry in recent years. For example, solid-state drives using flash memory as storage medium are already broadly used as hard drives of computers, so as to improve an overall access performance of the computers.
Generally speaking, to prolong the lifetime of the rewritable non-volatile memory, the physical erasing units in the rewritable non-volatile memory should be used as evenly as possible. For example, the physical erasing units in the rewritable non-volatile memory may be divided into a data area and a spare area. A conventional wear leveling method is to switch the physical erasing units in the data area and the spare area after the rewritable non-volatile memory is operated for a fixed period of time or at a fixed time point, so that the physical erasing unit with a lower erase count in the data area may be changed to the spare area to be programmed or written.
When the physical erasing unit with a lower erase count in the data area is changed to the spare area, a physical erasing unit with a higher erase count is selected to be changed from the spare area to the data area. However, if the data stored in the physical erasing unit are data that are updated frequently, it is likely that the physical erasing unit is associated to the spare area again when the data are updated. However, in the next wear leveling operation, the physical erasing unit that is associated to the spare area again has a higher chance to be changed to the data area again because this physical erasing unit has an erase count higher than other physical erasing units. Thus, the physical erasing units of the rewritable non-volatile memory module are not used evenly. Thus, how to select the physical erasing unit for the wear leveling process to make the physical erasing units used evenly and thus effectively prolong the lifetime of the rewritable non-volatile memory is an issue that people having ordinary skills in the art should work on.
Nothing herein should be construed as an admission of knowledge in the prior art of any portion of the present invention. Furthermore, citation or identification of any document in this application is not an admission that such document is available as prior art to the present invention, or that any reference forms a part of the common general knowledge in the art.